package com.example.Laboratory.Mapper;

import com.example.Laboratory.Entity.Achievements_software;
import org.apache.ibatis.annotations.*;

import java.util.List;

@Mapper
public interface Achievements_softwareMapper {

    //增加科研成果-软件著作权信息
    @Insert("INSERT INTO achievements_software(achievements_software_name,achievements_software_type,achievements_software_person,achievements_software_year)VALUES(#{achievements_software_name},#{achievements_software_type},#{achievements_software_person},#{achievements_software_year})")
    int addAchievements_software (Achievements_software s);

    //根据id删除信息
    @Delete("Delete from achievements_software where Achievements_software_id=#{Achievements_software_id}")
    int deleteAchievements_software (int Achievements_software_id);

    //查找全表信息
    @Select("select * from achievements_software")
    List<Achievements_software> researchAchievements_software ( );


    //修改全部信息
    @Update("UPDATE achievements_software SET achievements_software_name=#{achievements_software_name},achievements_software_type=#{achievements_software_type},achievements_software_person=#{achievements_software_person},achievements_software_year=#{achievements_software_year} WHERE achievements_software_id=#{achievements_software_id}")
    int reviseAchievements_software (Achievements_software s);
}
